import { get,post, downloadExcel } from '@/utils/request'

export default {
  getUserDepartsTree: query => get('/api/admin/qywx/departAndUser/tree/v1', query),
  getUserPageList: query => post('/api/admin/user/page/list', query),
  syncQYWX: query => get('/api/admin/qywx/departAndUser/tree', query),
  getUserList: query => get('/api/admin/employee/list', query),
  getUserEventPageList: query => post('/api/admin/user/event/page/list', query),
  createUser: query => post('/api/admin/user/edit', query),
  selectUser: id => post('/api/admin/user/select/' + id),
  getCurrentUser: () => post('/api/admin/user/current'),
  updateUser: query => post('/api/admin/user/update', query),
  changeStatus: id => post('/api/admin/user/changeStatus/' + id),
  deleteUser: id => post('/api/admin/user/delete/' + id),
  selectByUserName: query => post('/api/admin/user/selectByUserName', query),
  userFilter: query => get('/api/admin/employee/list/kv', query),
  updateStatus: query => get('/api/admin/employee/updateStatus', query),
  exportUserlist: query => downloadExcel('/api/admin/employee/exportList', query),
}
